<?php
/**
 * Created by JetBrains PhpStorm.
 * User: FangXuanLing
 * Date: 13-11-19
 * Time: 下午1:36
 * To change this template use File | Settings | File Templates.
 */
?>
<div >
<strong><?php echo $name ?>  |   <a href="<?php echo Yii::app()->createUrl("admin/category/add")  ?>">添加</a></strong>

    <table>
        <tr>
            <td>ID</td><td>分类名称</td><td>操作</td>
        </tr>
        <?php foreach ($data as $d) { ?>
        <tr>
            <td><?php echo $d->cid ?></td>
            <td><?php echo $d->category_name ?></td>
            <td><a href="<?php echo Yii::app()->createUrl('admin/category/edit',array('cid'=>$d->cid)) ?>">编辑</a>|
            <a href="<?php echo Yii::app()->createUrl('admin/category/del',array('cid'=>$d->cid)) ?>">删除</a></td>
        </tr>
        <?php } ?>
    </table
</div>